//
//  ProductViewCell.h
//  FruitsWholesaler
//
//  Created by sgone-2 on 15/11/20.
//  Copyright © 2015年 sgone. All rights reserved.
//

#import <UIKit/UIKit.h>

@protocol MenutableViewCellDataSource;
@protocol MenuTableViewCellDelegate;

@interface ProductViewCell : UITableViewCell


@property (strong, nonatomic) id <MenutableViewCellDataSource> dataSource;
@property (strong, nonatomic) id <MenuTableViewCellDelegate> delegate;
//是否已经视图打开
@property (assign, nonatomic) BOOL isOpenMenu;
//下拉菜单视图
@property (weak, nonatomic) IBOutlet UIView *menuView;

/**
 *  构建下拉视图
 */
- (void)buildMenuView;




@property(nonatomic,strong) UIImageView *imageSJ;

@property (weak, nonatomic) IBOutlet UIImageView *image1;

@property (weak, nonatomic) IBOutlet UILabel *labelName;

@property (weak, nonatomic) IBOutlet UILabel *labelUnit;


@property (weak, nonatomic) IBOutlet UILabel *labelPrice;


@property (weak, nonatomic) IBOutlet UILabel *lableSJ;


@property (weak, nonatomic) IBOutlet UIButton *btn1;


- (IBAction)btn1:(UIButton *)sender;


-(void)loadCell:(NSDictionary *)dic2 buttonTitle:(NSString *)title;



//展现勾选进行操作
@property (weak, nonatomic) IBOutlet UIImageView *imageGou;



@property (weak, nonatomic) IBOutlet UIButton *buttonGou;

- (IBAction)buttonGOu:(id)sender;


@end




@protocol MenutableViewCellDataSource <NSObject>

@required
- (NSMutableArray *)dataSourceForMenuItem;

@end

@protocol MenuTableViewCellDelegate <NSObject>

@optional
- (void)didOpenMenuAtCell:(ProductViewCell *)menuCell withMoreButton:(UIButton *)moreButton;

- (void)menuTableViewCell:(ProductViewCell *)menuTableViewCell didSeletedMentItemAtIndex:(NSInteger)menuItemIndex;

@end



